<template>
  <div>
    <h1>第九题希望讲一下</h1>
    <div class="colorBox" :style="{ background: `rgb(${a},${b},${c})` }"></div>
    <div>
      R:<input type="range" max="250" v-model="a" /> G:<input
        type="range"
        max="250"
        v-model="b"
      />
      B:<input type="range" max="250" v-model="c" />
    </div>
  </div>
</template>

<script>
export default {
  name: "PageH",
  data() {
    return {
      a: 0,
      b: 0,
      c: 0,
    };
  },
  methods: {
    fn() {
      this.a = this.b = this.c = Math.floor(Math.random() * 255);
    },
  },
};
</script>

<style scoped>
.colorBox {
  width: 200px;
  height: 200px;
  border: 1px solid #ccc;
}
</style>
